#include "stdafx.h"
#include "CppUnitTest.h"

#include "../mackinac/mackinac.h"

using namespace Microsoft::VisualStudio::CppUnitTestFramework;

namespace mctest
{		
	TEST_CLASS(IMCCBridgeTest)
	{
	public:

		TEST_METHOD(LoginTest)
		{
			auto& imcc = sap::businessone::webbridge::IMCCBridge::instance();

			auto ret = imcc.login(L"some uri", L"manager", L"1234");
			ret = imcc.deployPackage(L"some package...");
			wstring s = imcc.getMessageList(L"some filter... hha", true, 120, 13.75f, 489.8980f, 7752333);
			s = imcc.getMessageList(L"some filter... hha", true, 120, 13.75f, 489.8980f, 7752333);
			s = imcc.getMessageList(L"<!DOCTYPE html><html><head><meta content=~text/html; charset=UTF-8~ http-equiv=~content-type~><link rel=dns-prefetch href=//ssl.gstatic.com><link rel=dns-prefetch href=//csi.gstatic.com><link rel=dns-prefetch href=//www.google.com><meta name=keywords content=~translate, translations, translation, translator, machine translation, online translation~><meta name=description content=~Google&#39;s free online language translation service instantly translates text and web pages. This translator supports: English, Afrikaans, Albanian, Arabic, Armenian, Azerbaijani, Basque, Belarusian, Bengali, Bosnian, Bulgarian, Catalan, Cebuano, Chinese, Croatian, Czech, Danish, Dutch, Esperanto, Estonian, Filipino, Finnish, French, Galician, Georgian, German, Greek, Gujarati, Haitian Creole, Hausa, Hebrew, Hindi, Hmong, Hungarian, Icelandic, Igbo, Indonesian, Irish, Italian, Japanese, Javanese, Kannada, Khmer, Korean, Lao, Latin, Latvian, Lithuanian, Macedonian, Malay, Maltese, Maori, Marathi, Mongolian, Nepali, Norwegian, Persian, Polish, Portuguese, Punjabi, Romanian, Russian, Serbian, Slovak, Slovenian, Somali, Spanish, Swahili, Swedish, Tamil, Telugu, Thai, Turkish, Ukrainian, Urdu, Vietnamese, Welsh, Yiddish, Yoruba, Zulu~><meta name=robots content=noodp><meta name=google content=notranslate><link rel=~canonical~ href=~http://translate.google.cn/?hl=en~><title>Google Translate</title><link rel=~search~ type=~application/opensearchdescription+xml~ href=~/opensearch.xml?hl=en~ title=~Google Translate~><script>JS_ERR_COUNT = 0;JS_ERR_ARR = [];JS_LOADED = false;function _gtErr(e,url,line){++JS_ERR_COUNT;var i=new Image();var err='e='+e.substr(0,1500)+',url='+url.substr(0,400)+',line='+line+',count='+JS_ERR_COUNT;if (JS_ERR_COUNT<10) {JS_ERR_ARR.push(err);}i.src='/gen204?jserr='+encodeURIComponent(err);i.onload=function(){i.onload=null;};}window.onerror=_gtErr;</script><script>(function(){(function(){function e(a){this.t={};this.tick=function(a,c,b){var d=void 0!=b?b:(new Date).getTime();this.t[a]=[d,c];if(void 0==b)try{window.console.tim", true, 120, 13.75f, 489.8980f, 7752333);
			bool flag = imcc.isCompanyEnabled();
			imcc.test();
			imcc.test();

		}

	};
}